@extends('layouts.app')
@section('content')
<div class="page-container">
	<div class="cl  bg-1 bk-gray">
        <span class="">&nbsp;&nbsp;共有数据：<strong>{{count($sort)}}</strong> 条</span> 
        <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:history.go(-1);" title="刷新" >返回</a>
     </div>
	<div class="mt-20">
	<table class="table table-border table-bordered table-hover table-bg table-sort">
		<thead>
			<tr class="text-c">
				<th width="80">股票名称</th>
				<th width="80">所属行业</th>
				<th width="80">股票代码</th>
				<th width="100">最高价</th>
				<th width="40">最新价</th>
				<th width="90">涨跌比</th>
                <th width="100">操作</th>
			</tr>
		</thead>
		<tbody>
              @foreach ($sort as $key=>$val)
                    <tr class="text-c">
						<td>{{$val['name']}}</td>
						<td>{{$val['industry']}}</td>
                        <td>{{$key}}</td>
                        <td>{{$val['highprice']}}</td>
                        <td>{{$val['newprice']}}</td>
                        <td>
                        @if($val['percent']>0)
                            <strong style='color:green;' >-{{$val['percent']}}%</strong>
                        @else
                            <strong style='color:green;' >{{$val['percent']}}</strong>
                        @endif
                        </td>
                        <td> 
                        @if(substr($key,0,1)==6)
                            <a href='http://quotes.money.163.com/0{{$key}}.html' target='_blank' > 查看行情</a>
                        @else
                        <a href='http://quotes.money.163.com/1{{$key}}.html' target='_blank' > 查看行情</a> 
                        @endif
                        </td> 
                    </tr>
             @endforeach
		</tbody>
	</table>
	</div>
</div>

@endsection